From: Aryeh Gregor Date: Sun, 28 Feb 2010 19:34:23 +0000 (+0000) Subject: Spell variables correctly X-Git-Tag: 1.31.0-rc.0~37579 X-Git-Url: http://git.cyclocoop.org/%7D%7Cconcat%7B?a=commitdiff_plain;h=2e29d785da9be8c9ef451fb4a41dd927aaba1d02;p=lhc%2Fweb%2Fwiklou.git Spell variables correctly --- diff --git a/includes/Preferences.php b/includes/Preferences.php index daf9309535..a3849385d6 100644 --- a/includes/Preferences.php +++ b/includes/Preferences.php @@ -1261,18 +1261,18 @@ class Preferences { ); if( $wgEnableEmail ) { - $newadr = $formData['emailaddress']; - $oldadr = $wgUser->getEmail(); - if( ( $newadr != '' ) && ( $newadr != $oldadr ) ) { + $newaddr = $formData['emailaddress']; + $oldaddr = $wgUser->getEmail(); + if( ( $newaddr != '' ) && ( $newaddr != $oldaddr ) ) { # the user has supplied a new email address on the login page # new behaviour: set this new emailaddr from login-page into user database record - $wgUser->setEmail( $newadr ); + $wgUser->setEmail( $newaddr ); # but flag as "dirty" = unauthenticated $wgUser->invalidateEmail(); if( $wgEmailAuthentication ) { # Mail a temporary password to the dirty address. # User can come back through the confirmation URL to re-enable email. - $result = $wgUser->sendConfirmationMail( $oldadr != '' ); + $result = $wgUser->sendConfirmationMail( $oldaddr != '' ); if( WikiError::isError( $result ) ) { return wfMsg( 'mailerror', htmlspecialchars( $result->getMessage() ) ); } elseif( $entryPoint == 'ui' ) { @@ -1280,10 +1280,10 @@ class Preferences { } } } else { - $wgUser->setEmail( $newadr ); + $wgUser->setEmail( $newaddr ); } - if( $oldadr != $newadr ) { - wfRunHooks( 'PrefsEmailAudit', array( $wgUser, $oldadr, $newadr ) ); + if( $oldaddr != $newaddr ) { + wfRunHooks( 'PrefsEmailAudit', array( $wgUser, $oldaddr, $newaddr ) ); } }